package com.wontube.smr.remote;

import com.wontube.client.modle.vo.ClientSession;
import com.wontube.core.annotation.NoLoginSupport;
import com.wontube.core.pub.SessionManager;
import com.wontube.core.pub.servlet.handlers.BasicHandler;
import com.wontube.smr.client.IExitSessionHandler;

/**
 * 冗余client.remote.IExitSessionHandler接口
 * @author tanggf(2012-9-10)
 *
 */
@NoLoginSupport
public class ExitSessionHandler extends BasicHandler implements IExitSessionHandler {
	@Override
	public Boolean exit() {
		ClientSession session = super.getContext().getSession();
		if (session != null) {
			return SessionManager.manager.deleteSession(session.getSessionId());
		}
		
		return false;
	}
}
